home *** CD-ROM | disk | FTP | other *** search
/ Delphi 2 - Developers' Solutions / Delphi 2 Developers' Solutions.iso / dds / sharware / debmono / mono1.pas < prev    next >
Encoding:
Pascal/Delphi Source File  |  1995-10-02  |  1.3 KB  |  67 lines

  1. unit Mono1;
  2.  
  3. interface
  4.  
  5. uses
  6.   SysUtils, WinTypes, WinProcs, Messages, Classes, Graphics, Controls,
  7.   Forms, Dialogs, StdCtrls, WinCrt, debmono;
  8.  
  9. type
  10.   TForm1 = class(TForm)
  11.     Button1: TButton;
  12.     Button2: TButton;
  13.     Button3: TButton;
  14.     Button4: TButton;
  15.     Button5: TButton;
  16.     DM: TDebMono;
  17.     procedure Button2Click(Sender: TObject);
  18.     procedure Button1Click(Sender: TObject);
  19.     procedure Button3Click(Sender: TObject);
  20.     procedure Button4Click(Sender: TObject);
  21.     procedure Button5Click(Sender: TObject);
  22.   private
  23.     { Private declarations }
  24.   public
  25.     { Public declarations }
  26.   end;
  27.  
  28.  
  29. var
  30.   Form1: TForm1;
  31.   ctr: word;
  32.  
  33. implementation
  34.  
  35. {$R *.DFM}
  36.  
  37. procedure TForm1.Button1Click(Sender: TObject);
  38. begin
  39. Inc(ctr);
  40. DM.Text := Format('Called %.2d %.4x %p',[ctr,ctr,ptr($1234,$6789)]);
  41. DM.Text := Format('!%.2dStat %.4d',[ctr,ctr]);
  42. end;
  43.  
  44. procedure TForm1.Button2Click(Sender: TObject);
  45. begin
  46. DM.Text := 'Pgm Ended';
  47. Halt;
  48. end;
  49.  
  50. procedure TForm1.Button3Click(Sender: TObject);
  51. begin
  52. dm.Nodisplay := 0;
  53. end;
  54.  
  55. procedure TForm1.Button4Click(Sender: TObject);
  56. begin
  57. dm.Nodisplay := 1;
  58. end;
  59.  
  60. procedure TForm1.Button5Click(Sender: TObject);
  61. begin
  62. Inc(ctr);
  63. MonoText(Format('Testing as function, ctr=%d',[ctr]));
  64. end;
  65.  
  66. end.
  67.